package controle;

import java.util.List;

import modelo.Cd;
import DAOs.CdDAO;
import DAOs.DAOFactory;

public class ControleCd {
	
	public void salvar(Cd cd){
		CdDAO cdDao= DAOFactory.getCdDAO();
		cdDao.salvar(cd);
	}
	
	public List<Cd> findAll(){
		CdDAO cdDao=DAOFactory.getCdDAO();
		return cdDao.findAll();
	}
	
	public void alterar(Cd cd){
		CdDAO cdDao= DAOFactory.getCdDAO();
		cdDao.alterar(cd);
	}
	
	public void deletar(Cd cd){
		CdDAO cdDao=DAOFactory.getCdDAO();
		cdDao.deletar(cd);
	}
}
